// 加载React
import React from 'react'
// 加载Component
import { Component } from 'react'

import styles from './emptyStyle.less'

import { config } from '../../utils'
import Cookie from 'js-cookie'


import empty from '../../assets/img/empty.png'
import { size } from 'lodash'


// 导出组件
export default class extends Component {
  // 构造函数
  constructor(props, context) {
    super(props, context)
    this.state = {
      homeInfo:{
        // formationUpdate: '',
        // activityUpdate: '',
        // bookingRoom: '',
        // eventRegistration:'',
        // applyCooperation:''
      }
    }
    // this.queryUserDetailText()
    
  }
  
  // 执行退出
  async queryUserDetailText() {
    let self = this
    // if (!config.isLogin) {
    // }
    // 注销登录
    let { success,msg } = await queryUserDetailText({
      // userType: 1
    })
    
    if (success) {

    }
  }

  queryMenuRoot(id){
    
  }
  
  //准备：即将被重新渲染，状态未变化
  componentWillMount() {
  }

  //准备：即将被重新渲染，状态未变化
  componentWillUpdate(nextProps, nextState) {}

  //完成：正在被重新渲染，状态已变化
  componentDidUpdate(prevProps, prevState) {}

  // 已加载组件，收到新属性时调用
  componentWillReceiveProps(nextProps) {}

  // 已插入真实DOM
  componentDidMount() {}

  //组件将被卸载
  componentWillUnmount(){}

  // 初始状态或状态变化会触发render
  render(ReactElement, DOMElement, callback) {
    let homeInfo = this.state.homeInfo
    const userName = Cookie.get(config.cookie.userName);
    return (
      <div className={styles.welcome}>
        <img src={empty} width={800} height={600} />
        <span className={styles.desc}>功能开发中，敬请期待</span>
      </div>
    )
  }
}
